package services;

import dao.ISupplier;
import factory.SupplierDaoFactory;
import vo.Supplier;

import java.util.List;

public class SupplierServicempl implements ISupplierService{
        ISupplier iSupplier= SupplierDaoFactory.getInstance();//获取具体操作类的对象
    @Override
    public boolean add(Supplier supplier) {
        return iSupplier.add(supplier);
    }

    @Override
    public boolean delete(Supplier supplier) {
        return iSupplier.delete(supplier);
    }

    @Override
    public boolean modify(Supplier supplier) {
        return iSupplier.modify(supplier);
    }

    @Override
    public Supplier getcustombyid(String name) {
        return iSupplier.getcustombyid(name);
    }

    @Override
    public List<Supplier> getall() {
        return iSupplier.getall();
    }
}
